<include file="public@agent_header"/>
<link href="__STATIC__/css/layui.css" rel="stylesheet" />
<link href="__STATIC__/css/admin.css" rel="stylesheet" />
</head>
<body>
<div class="wrap">
    <div class="row">
        <div class="layui-card-body">
            <div class="layui-carousel layadmin-carousel layadmin-backlog" lay-anim="" lay-indicator="inside" lay-arrow="none" style="width: 100%; height: 80px!important;">
                <div carousel-item="">
                    <ul class="layui-row layui-col-space10 layui-this">
                        <li class="layui-col-xs3">
                            <a href="javascript:;" class="layadmin-backlog-body">
                                <h3>总用户数</h3>
                                <p><cite>{$total_num}</cite>人</p>
                            </a>
                        </li>
                        <li class="layui-col-xs3">
                            <a href="javascript:;" class="layadmin-backlog-body">
                                <h3>今日新用户数</h3>
                                <p><cite>{$today_num}</cite>人</p>
                            </a>
                        </li>
                        <li class="layui-col-xs3">
                            <a href="javascript:;" class="layadmin-backlog-body">
                                <h3>本月新用户数</h3>
                                <p><cite>{$month_num}</cite>人</p>
                            </a>
                        </li>
                        <li class="layui-col-xs3">
                            <a href="javascript:;" class="layadmin-backlog-body">
                                <h3>用户总资产数</h3>
                                <p><cite>{$balance_sum}</cite>USDT</p>
                            </a>
                        </li>
                    </ul>
                </div>
            </div>
        </div>
    </div>
    <ul class="nav nav-tabs">
        <li class="active"><a>用户列表</a></li>
    </ul>
    <form class="well form-inline margin-top-20" method="post" action="{:url('user/adminIndex/index')}">
        用户ID：
        <input class="form-control" type="text" name="uid" style="width: 200px;" value="{:input('request.uid')}"
               placeholder="请输入用户ID">
        关键字：
        <input class="form-control" type="text" name="keyword" style="width: 200px;" value="{:input('request.keyword')}"
               placeholder="邮箱/手机">
        <input type="submit" class="btn btn-primary" value="搜索"/>
        <a class="btn btn-danger" href="{:url('user/adminIndex/index')}">清空</a>
    </form>
    <form method="post" class="js-ajax-form">
        <table class="table table-hover table-bordered">
            <thead>
            <tr>
                <th>ID</th>
                <th>手机</th>
                <th>{:lang('EMAIL')}</th>
                <th>{:lang('REGISTRATION_TIME')}</th>
                <th>邀请码</th>
                <th>推荐人</th>
                <th>会员等级</th>
                <th>币种</th>
                <th>余额</th>
                <th>冻结</th>
                <th>个人盈亏</th>
                <th>伞下盈亏</th>
                <th>{:lang('STATUS')}</th>
            </tr>
            </thead>
            <tbody>
            <php>
                $user_statuses=array("0"=>lang('USER_STATUS_BLOCKED'),"1"=>lang('USER_STATUS_ACTIVATED'),"2"=>lang('USER_STATUS_UNVERIFIED'));
            </php>
            <foreach name="list" item="vo">
                <tr>
                    <td>{$vo.id}</td>
                    <td>{$vo.mobile}</td>
                    <td>{$vo.user_email}</td>
                    <td>{:date('Y-m-d H:i:s',$vo['create_time'])}</td>
                    <td>{$vo.invitation_code}</td>
                    <td>{:recommender_info($vo.recommender_code)}</td>
                    <td>{$vo.level_name}</td>
                    <td>USDT</td>
                    <td>{:floatval($vo.balance)}</td>
                    <td>{:floatval($vo.frozen_balance)}</td>
                    <td>{:floatval($vo.profit_loss)}</td>
                    <td>{:down_profit_loss($vo.id)}</td>
                    <td>
                        <switch name="vo.user_status">
                            <case value="0">
                                <span class="label label-danger">{$user_statuses[$vo['user_status']]}</span>
                            </case>
                            <case value="1">
                                <span class="label label-success">{$user_statuses[$vo['user_status']]}</span>
                            </case>
                            <case value="2">
                                <span class="label label-warning">{$user_statuses[$vo['user_status']]}</span>
                            </case>
                        </switch>
                    </td>
                </tr>
            </foreach>
            </tbody>
        </table>
        <div class="pagination">{$page}</div>
    </form>
</div>
<script src="__STATIC__/js/admin.js"></script>
</body>
</html>